Many electronic devices include displays having viewing areas in which information is visibly presented. Such viewing areas may include an underlying encoded pattern which reflects pulses of near infrared light to indicate a position of an electro-optical pen.